import time

from selenium.webdriver.common.by import By

from Base.base_page import WebBasePage


class LikeFullScreenPage(WebBasePage):
    def __init__(self):
        super().__init__()
        # 爱心按钮
        self.like_button = (By.XPATH,'/html/body/div[1]/div[1]/section/div/div/div/div[1]/div/div/div[1]/div/div[1]/div/div[2]/div/div[5]/div[2]/div[2]/div[2]/div/div/div/div/div[2]/img')
        # 全屏按钮
        self.full_screen_button = (By.XPATH,'//*[@class="enter-fullscreen"]')
        # 爱心按钮
        # 退出全屏
        self.full_exit_button = (By.XPATH,'//*[@class="exit-fullscreen"]')
    def to_like_full_screen(self):
        self.click_element(self.find_element(self.like_button))
        self.click_element(self.find_element(self.full_screen_button))
        self.click_element(self.find_element(self.full_exit_button))
        self.click_element(self.find_element(self.like_button))
